<template>
	<view class="container">
		<custom-header title="关于我们"></custom-header>

		<image class="logo" src="../../static/images/ic_login_nav_logo.png" v-if="isShow"></image>

		<view style="margin-top: 22rpx; color: black; font-size: 28rpx; font-weight: bold;" v-if="isShow">惠收卡</view>

		<view class="content-container" v-if="isShow">
			<view class="info-item" data-url="https://file.huishouka.com.cn/html/1742962317970.html" @click="gouto">
				<text class="item-label">用户协议</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
			<view class="divider"></view>
			<view class="info-item" data-url="https://file.huishouka.com.cn/html/1742963949398.html" @click="gouto">
				<text class="item-label">隐私政策</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
			<view class="divider"></view>
			<view class="info-item" data-url="/pages/sale-flow/sale-flow" @click="navigateTo">
				<text class="item-label">卖卡流程</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
			<view class="divider"></view>
			<view class="info-item" data-url="/pages/company/company" @click="navigateTo">
				<text class="item-label">企业招商</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
			<view class="divider"></view>
			<view class="info-item" data-url="https://file.huishouka.com.cn/html/1742964957582.html" @click="gouto">
				<text class="item-label">回收说明</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
			<view class="divider"></view>
			<view class="info-item" data-url="https://file.huishouka.com.cn/html/1742964888037.html" @click="gouto">
				<text class="item-label">免责声明</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
			<view class="divider"></view>
			<view class="info-item" data-url="https://file.huishouka.com.cn/html/1742968267434.html" @click="gouto">
				<text class="item-label">企业资质</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
		</view>
		
		<view class="content-container" v-else>
			<view class="info-item" data-url="https://file.huishouka.com.cn/html/1742962317970.html" @click="gouto">
				<text class="item-label">用户协议</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
			<view class="divider"></view>
			<view class="info-item" data-url="https://file.huishouka.com.cn/html/1742963949398.html" @click="gouto">
				<text class="item-label">隐私政策</text>
				<image src="../../static/images/arrow_right.png" style="width: 12rpx; height: 22rpx;"></image>
			</view>
		</view>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				isShow: uni.getStorageSync("isShow"),
			};
		},
		methods: {
			navigateTo(e) {
				let url = e.target.dataset.url
				uni.navigateTo({
					url: url
				})
			},
			// 跳转到隐私
			gouto(e) {
				let url = e.target.dataset.url
				this.$app.openUrl(url, false)
			},
		}
	}
</script>

<style lang="scss">
	.container {
		display: flex;
		flex-direction: column;
		height: 100vh;
		width: 100vw;
		align-items: center;
	}

	.logo {
		height: 160rpx;
		width: 160rpx;
		margin-top: 76rpx;
	}

	.content-container {
		margin-top: 110rpx;
		padding: 0 70rpx;
		width: 100%;
	}

	.info-item {
		display: flex;
		width: 100%;
		justify-content: space-between;
		align-items: center;
		padding: 30rpx 0;

		.item-label {
			font-size: 28rpx;
			color: #000;
		}
	}

	.divider {
		height: 2rpx;
		background-color: rgba(0, 0, 0, 0.09);
	}
</style>